<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Initiate a chunked reply</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="eventhttprequest.sendreplyend.html">EventHttpRequest::sendReplyEnd</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="class.eventlistener.html">EventListener</a></div>
 <div class="up"><a href="class.eventhttprequest.html">EventHttpRequest</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="eventhttprequest.sendreplystart" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">EventHttpRequest::sendReplyStart</h1>
  <p class="verinfo">(PECL event &gt;= 1.4.0-beta)</p><p class="refpurpose"><span class="refname">EventHttpRequest::sendReplyStart</span> &mdash; <span class="dc-title">Initiate a chunked reply</span></p>

 </div>
 <div class="refsect1 description" id="refsect1-eventhttprequest.sendreplystart-description">
  <h3 class="title">说明</h3>
  <div class="methodsynopsis dc-description">
   <span class="modifier">public</span>
   <span class="type"><span class="type void">void</span></span> 
   <span class="methodname"><strong>EventHttpRequest::sendReplyStart</strong></span>
    ( <span class="methodparam">
    <span class="type">int</span>
     <code class="parameter">$code</code>
   </span>
   , <span class="methodparam">
    <span class="type">string</span>
     <code class="parameter">$reason</code>
   </span>
   )</div>

  <p class="para rdfs-comment">
   Initiate a reply that uses
   <em>Transfer-Encoding</em>
   <em>chunked</em>
   .
  </p>
  <p class="para">
   This allows the caller to stream the reply back to the client and is useful
   when either not all of the reply data is immediately available or when
   sending very large replies.
  </p>
  <p class="para">
   The caller needs to supply data chunks with
   <span class="methodname"><a href="eventhttprequest.sendreplychunk.html" class="methodname">EventHttpRequest::sendReplyChunk()</a></span>
   and complete the reply by calling
   <span class="methodname"><a href="eventhttprequest.sendreplyend.html" class="methodname">EventHttpRequest::sendReplyEnd()</a></span>
   .
  </p>
 </div>

 <div class="refsect1 parameters" id="refsect1-eventhttprequest.sendreplystart-parameters">
  <h3 class="title">参数</h3>
  <dl>

   
    <dt>

     <em><code class="parameter">code</code></em>
    </dt>

    <dd>

     <p class="para">
      The HTTP response code to send.
     </p>
    </dd>

   
   
    <dt>

     <em><code class="parameter">reason</code></em>
    </dt>

    <dd>

     <p class="para">
      A brief message to send with the response code.
     </p>
    </dd>

   
  </dl>

 </div>

 <div class="refsect1 returnvalues" id="refsect1-eventhttprequest.sendreplystart-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">
   没有返回值。
  </p>
 </div>

 <div class="refsect1 seealso" id="refsect1-eventhttprequest.sendreplystart-seealso">
  <h3 class="title">参见</h3>
  <ul class="simplelist">
   <li class="member">
    <span class="methodname"><a href="eventhttprequest.sendreplychunk.html" class="methodname" rel="rdfs-seeAlso">EventHttpRequest::sendReplyChunk()</a> - Send another data chunk as part of an ongoing chunked reply</span>
   </li>
   <li class="member">
    <span class="methodname"><a href="eventhttprequest.sendreplyend.html" class="methodname" rel="rdfs-seeAlso">EventHttpRequest::sendReplyEnd()</a> - Complete a chunked reply, freeing the request as appropriate</span>
   </li>
  </ul>
 </div>

</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="eventhttprequest.sendreplyend.html">EventHttpRequest::sendReplyEnd</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="class.eventlistener.html">EventListener</a></div>
 <div class="up"><a href="class.eventhttprequest.html">EventHttpRequest</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>
